<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" layout:decorate="main"
      xmlns:layout="http://www.ultraq.net.nz/web/thymeleaf/layout">
<head>
    <title>客户开发计划执行开发计划页面</title>
    <link th:href="@{/localCss/add.css}" href="/static/localCss/add.css" rel="stylesheet">
</head>
<body>
<div layout:fragment="content">
    <div class="">
        <div class="clearfix"></div>
        <div class="row">
            <div class="col-md-12 col-sm-12 col-xs-12">
                <div class="x_panel">
                    <div class="x_title">
                        <h2>执行开发计划 <i class="fa fa-user"></i></h2>
                        <div class="clearfix"></div>
                    </div>
                    <div class="x_content">
                        <div class="clearfix"></div>
                        <form class="form-horizontal form-label-left" action="" method="post">
                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcCustName"> 客户名称 <span
                                        class="required"></span>
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcCustName" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcCustName"
                                           required="required"
                                           placeholder="请输入客户名称" type="text" th:value="${salChance.chcCustName}"/>
                                </div>
                            </div>
                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcLinkman"> 负责人
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcLinkman" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcLinkman"
                                           placeholder="请输入负责人" type="text" th:value="${salChance.chcLinkman}"/>
                                </div>
                            </div>

                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcTel"> 公司电话
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcTel" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcTel"
                                           placeholder="请输入公司电话" type="text" th:value="${salChance.chcTel}"/>
                                </div>
                            </div>

                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcTitle"> 概要
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcTitle" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcTitle"
                                           placeholder="请输入概要" type="text" th:value="${salChance.chcTitle}"/>
                                </div>
                            </div>

                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcSource"> 机会来源
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcSource" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcSource"
                                           placeholder="请输入概要" type="text" th:value="${salChance.chcSource}"/>
                                </div>
                            </div>

                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcRate"> 成功几率（%）
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcRate" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcRate"
                                           placeholder="请输入概要" type="text" th:value="${salChance.chcRate}"/>
                                </div>
                            </div>

                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcDueDate"> 指派时间
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                    <input id="chcDueDate" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                           data-validate-length-range="10" data-validate-words="1" name="chcDueDate"
                                           placeholder="请输入时间" type="date"
                                           th:value="${#dates.format(salChance.chcDueDate, 'yyyy-MM-dd')}"/>
                                </div>
                            </div>

                            <div class="item form-group">
                                <label class="control-label col-md-3 col-sm-3 col-xs-12" for="chcDesc"> 机会描述
                                </label>
                                <div class="col-md-6 col-sm-6 col-xs-12">
                                <textarea id="chcDesc" class="form-control col-md-7 col-xs-12" readonly="readonly"
                                          data-validate-length-range="10" data-validate-words="1" name="chcDesc"
                                          th:text="${salChance.chcDesc}"></textarea>
                                </div>
                            </div>
                        </form>

                        <table id="datatable-responsive"
                               class="table table-striped table-bordered dt-responsive nowrap dataTable no-footer dtr-inline collapsed"
                               cellspacing="0" width="100%" role="grid"
                               aria-describedby="datatable-responsive_info" style="width: 100%;">
                            <thead>
                            <tr role="row">
                                <th class="sorting" tabindex="0"
                                    aria-controls="datatable-responsive" rowspan="1" colspan="1"
                                    aria-label="Last name: activate to sort column ascending">
                                    日期
                                </th>
                                <th class="sorting" tabindex="0"
                                    aria-controls="datatable-responsive" rowspan="1" colspan="1"
                                    aria-label="Last name: activate to sort column ascending">
                                    计划项
                                </th>
                                <th class="sorting" tabindex="0"
                                    aria-controls="datatable-responsive" rowspan="1" colspan="1"
                                    aria-label="Last name: activate to sort column ascending">
                                    执行效果
                                </th>
                                <th class="sorting" tabindex="0"
                                    aria-controls="datatable-responsive" rowspan="1" colspan="1"
                                    aria-label="Last name: activate to sort column ascending">
                                    操作
                                </th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr th:each="salPlan : ${salPlanList}" role="row" class="odd">
                                <td th:text="${#dates.format(salPlan.plaDate, 'yyyy-MM-dd HH:mm:ss')}">plaDate</td>
                                <td th:text="${salPlan.plaTodo}"></td>
                                <td>
                                    <input type="text" class="salResult" name="salResult" th:disabled="${salPlan.plaResult ne null}"
                                           th:value="${salPlan.plaResult}">
                                </td>
                                <td>
                                    <div class="btn-group" th:styleappend="${salPlan.plaResult ne null} ? 'display: none;'">
                                        <a class="editPlan" style="cursor: pointer"
                                           data-toggle="tooltip" th:onclick="|EditPlaResult(this, '${salPlan.plaId}')|"
                                           data-placement="top" title=""
                                           data-original-title="保存">保存</a>
                                    </div>
                                </td>
                            </tr>
                            </tbody>
                        </table>

                        <div class="form-group">
                            <div class="col-md-6 col-md-offset-3">
                                <button type="button" class="btn btn-primary" th:onclick="|Lose('${salChance.chcId}')|">终止开发
                                </button>
                                <button type="button" class="btn btn-primary" onclick="window.history.back();">返回
                                </button>
                                <button type="button" class="btn btn-primary" th:onclick="|Win('${salChance.chcId}')|">开发成功
                                </button>
                                <br/>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</body>
</html>